/*
 * Make3DArray.c
 *
 *  Created on: Apr 11, 2010
 *      Author: second
 */

#include "smalloc.h"
#include "stdio.h"
#include "stdlib.h"

int Make3DArray(int *nn, double* z){
	int n0,n1,n2,i,j,k;

	n0=*nn;
	n1=*(nn+1);
	n2=*(nn+2);

	z=(double ***) malloc(sizeof(double **)*n0);
	for(i=0;i<n0;i++){
		z[i]=(double **) malloc(sizeof(double *)*n1);
		for(j=0;j<n1;j++){
			z[i][j]=(double *) malloc(sizeof(double)*n2);
		}
	}


	for(i=0;i<n0;i++){
		for(j=0;j<n1;j++){
			for(k=0;k<n2;k++){
				z[i][j][k]=1.3;
			}
		}

	}
	printf(" %6d %10.3f \n",*nn, z[1][1][3]);
	return 1;
}
